// 类
import { User } from 'src/user/modules/user.entity';
import { Column, Entity, ManyToMany, PrimaryGeneratedColumn } from 'typeorm';

@Entity('roles')
export class Roles {
  @PrimaryGeneratedColumn('uuid')
  id: string;

  @Column({ comment: '名称', default: '' })
  name: string;

  @ManyToMany(() => User, user => user.roles)
  users: User[];
}
